using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._SpatialStatisticsTools._ModelingSpatialRelationships
{
    /// <summary>
    /// <para>Geographically Weighted Regression </para>
    /// <para>Performs Geographically Weighted Regression (GWR), which is a local form of linear regression that is used to model spatially varying relationships.</para>
    /// <para>执行地理加权回归 （GWR），这是一种局部形式的线性回归，用于对空间变化的关系进行建模。</para>
    /// </summary>    
    [DisplayName("Geographically Weighted Regression ")]
    public class GWR : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public GWR()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_features">
        /// <para>Input Features</para>
        /// <para>The feature class containing the dependent and explanatory variables.</para>
        /// <para>包含因变量和解释变量的要素类。</para>
        /// </param>
        /// <param name="_dependent_variable">
        /// <para>Dependent Variable</para>
        /// <para>The numeric field containing the observed values that will be modeled.</para>
        /// <para>包含将要建模的观测值的数值字段。</para>
        /// </param>
        /// <param name="_model_type">
        /// <para>Model Type</para>
        /// <para><xdoc>
        ///   <para>Specifies the type of data that will be modeled.</para>
        ///   <bulletList>
        ///     <bullet_item>Continuous (Gaussian)— The Dependent Variable value is continuous. The Gaussian model will be used, and the tool will perform ordinary least squares regression.</bullet_item><para/>
        ///     <bullet_item>Binary (Logistic)— The Dependent Variable value represents presence or absence. This can be either conventional 1s and 0s or continuous data that has been coded based on a threshold value. The Logistic regression model will be used.</bullet_item><para/>
        ///     <bullet_item>Count (Poisson)—The Dependent Variable value is discrete and represents events, such as crime counts, disease incidents, or traffic accidents. The Poisson regression model will be used.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定要建模的数据类型。</para>
        ///   <bulletList>
        ///     <bullet_item>连续（高斯）— 因变量值是连续的。将使用高斯模型，该工具将执行普通最小二乘回归。</bullet_item><para/>
        ///     <bullet_item>二进制 （Logistic）— 因变量值表示存在或不存在。这可以是传统的 1 和 0，也可以是根据阈值编码的连续数据。将使用 Logistic 回归模型。</bullet_item><para/>
        ///     <bullet_item>计数 （Poisson） - 因变量值是离散的，表示事件，例如犯罪计数、疾病事件或交通事故。将使用泊松回归模型。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// </param>
        /// <param name="_explanatory_variables">
        /// <para>Explanatory Variable(s)</para>
        /// <para>A list of fields representing independent explanatory variables in the regression model.</para>
        /// <para>表示回归模型中独立解释变量的字段列表。</para>
        /// </param>
        /// <param name="_output_features">
        /// <para>Output Features</para>
        /// <para>The new feature class containing the dependent variable estimates and residuals.</para>
        /// <para>包含因变量估计值和残差的新要素类。</para>
        /// </param>
        /// <param name="_neighborhood_type">
        /// <para>Neighborhood Type</para>
        /// <para><xdoc>
        ///   <para>Specifies whether the neighborhood used is constructed as a fixed distance or allowed to vary in spatial extent depending on the density of the features.</para>
        ///   <bulletList>
        ///     <bullet_item>Number of neighbors— The neighborhood size is a function of a specified number of neighbors included in calculations for each feature. Where features are dense, the spatial extent of the neighborhood is smaller; where features are sparse, the spatial extent of the neighborhood is larger.</bullet_item><para/>
        ///     <bullet_item>Distance band—The neighborhood size is a constant or fixed distance for each feature.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定所使用的邻域是构造为固定距离，还是允许根据要素的密度在空间范围内变化。</para>
        ///   <bulletList>
        ///     <bullet_item>邻域数 - 邻域大小是每个要素的计算中包含的指定数目邻域的函数。要素密集的地方，邻域的空间范围较小;要素稀疏的地方，邻域的空间范围较大。</bullet_item><para/>
        ///     <bullet_item>距离带 - 邻域大小是每个要素的常数或固定距离。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// </param>
        /// <param name="_neighborhood_selection_method">
        /// <para>Neighborhood Selection Method</para>
        /// <para><xdoc>
        ///   <para>Specifies how the neighborhood size will be determined. The neighborhood selected with the Golden search and Manual intervals options is based on minimizing the AICc value.</para>
        ///   <bulletList>
        ///     <bullet_item>Golden search—The tool will identify an optimal distance or number of neighbors based on the characteristics of the data using the golden section search method.</bullet_item><para/>
        ///     <bullet_item>Manual intervals— The neighborhoods tested will be defined by the values specified in the Minimum Number of Neighbors and Number of Neighbors Increment parameters when Number of neighbors is chosen for the Neighborhood Type parameter, or the Minimum Search Distance and Search Distance Increment parameters when Distance band is chosen for the Neighborhood Type parameter, as well as the Number of Increments parameter.</bullet_item><para/>
        ///     <bullet_item>User defined— The neighborhood size will be specified by either the Number of Neighbors or Distance Band parameter.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定如何确定邻域大小。使用黄金搜索和手动间隔选项选择的邻域基于最小化 AICc 值。</para>
        ///   <bulletList>
        ///     <bullet_item>黄金搜索 - 该工具将使用黄金分割搜索方法根据数据的特征识别最佳距离或邻居数量。</bullet_item><para/>
        ///     <bullet_item>手动间隔 - 当为邻域类型参数选择邻域数时，测试的邻域将由最小邻域数和邻域数增量参数中指定的值定义，或者当邻域类型参数选择距离带时，由最小搜索距离和搜索距离增量参数以及增量数参数中指定的值定义。</bullet_item><para/>
        ///     <bullet_item>用户定义 — 邻域大小将由邻居数或距离波段参数指定。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// </param>
        public GWR(object _in_features, object _dependent_variable, _model_type_value _model_type, List<object> _explanatory_variables, object _output_features, _neighborhood_type_value? _neighborhood_type, _neighborhood_selection_method_value? _neighborhood_selection_method)
        {
            this._in_features = _in_features;
            this._dependent_variable = _dependent_variable;
            this._model_type = _model_type;
            this._explanatory_variables = _explanatory_variables;
            this._output_features = _output_features;
            this._neighborhood_type = _neighborhood_type;
            this._neighborhood_selection_method = _neighborhood_selection_method;
        }
        public override string ToolboxName => "Spatial Statistics Tools";

        public override string ToolName => "Geographically Weighted Regression ";

        public override string CallName => "stats.GWR";

        public override List<string> AcceptEnvironments => ["cellSize", "geographicTransformations", "outputCoordinateSystem", "scratchWorkspace", "snapRaster", "workspace"];

        public override object[] ParameterInfo => [_in_features, _dependent_variable, _model_type.GetGPValue(), _explanatory_variables, _output_features, _neighborhood_type.GetGPValue(), _neighborhood_selection_method.GetGPValue(), _minimum_number_of_neighbors, _maximum_number_of_neighbors, _minimum_search_distance, _maximum_search_distance, _number_of_neighbors_increment, _search_distance_increment, _number_of_increments, _number_of_neighbors, _distance_band, _prediction_locations, _explanatory_variables_to_match, _output_predicted_features, _robust_prediction.GetGPValue(), _local_weighting_scheme.GetGPValue(), _coefficient_raster_workspace, _coefficient_raster_layers];

        /// <summary>
        /// <para>Input Features</para>
        /// <para>The feature class containing the dependent and explanatory variables.</para>
        /// <para>包含因变量和解释变量的要素类。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_features { get; set; }


        /// <summary>
        /// <para>Dependent Variable</para>
        /// <para>The numeric field containing the observed values that will be modeled.</para>
        /// <para>包含将要建模的观测值的数值字段。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Dependent Variable")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _dependent_variable { get; set; }


        /// <summary>
        /// <para>Model Type</para>
        /// <para><xdoc>
        ///   <para>Specifies the type of data that will be modeled.</para>
        ///   <bulletList>
        ///     <bullet_item>Continuous (Gaussian)— The Dependent Variable value is continuous. The Gaussian model will be used, and the tool will perform ordinary least squares regression.</bullet_item><para/>
        ///     <bullet_item>Binary (Logistic)— The Dependent Variable value represents presence or absence. This can be either conventional 1s and 0s or continuous data that has been coded based on a threshold value. The Logistic regression model will be used.</bullet_item><para/>
        ///     <bullet_item>Count (Poisson)—The Dependent Variable value is discrete and represents events, such as crime counts, disease incidents, or traffic accidents. The Poisson regression model will be used.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定要建模的数据类型。</para>
        ///   <bulletList>
        ///     <bullet_item>连续（高斯）— 因变量值是连续的。将使用高斯模型，该工具将执行普通最小二乘回归。</bullet_item><para/>
        ///     <bullet_item>二进制 （Logistic）— 因变量值表示存在或不存在。这可以是传统的 1 和 0，也可以是根据阈值编码的连续数据。将使用 Logistic 回归模型。</bullet_item><para/>
        ///     <bullet_item>计数 （Poisson） - 因变量值是离散的，表示事件，例如犯罪计数、疾病事件或交通事故。将使用泊松回归模型。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Model Type")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public _model_type_value _model_type { get; set; }

        public enum _model_type_value
        {
            /// <summary>
            /// <para>Continuous (Gaussian)</para>
            /// <para>Continuous (Gaussian)— The Dependent Variable value is continuous. The Gaussian model will be used, and the tool will perform ordinary least squares regression.</para>
            /// <para>连续（高斯）— 因变量值是连续的。将使用高斯模型，该工具将执行普通最小二乘回归。</para>
            /// </summary>
            [Description("Continuous (Gaussian)")]
            [GPEnumValue("CONTINUOUS")]
            _CONTINUOUS,

            /// <summary>
            /// <para>Binary (Logistic)</para>
            /// <para>Binary (Logistic)— The Dependent Variable value represents presence or absence. This can be either conventional 1s and 0s or continuous data that has been coded based on a threshold value. The Logistic regression model will be used.</para>
            /// <para>二进制 （Logistic）— 因变量值表示存在或不存在。这可以是传统的 1 和 0，也可以是根据阈值编码的连续数据。将使用 Logistic 回归模型。</para>
            /// </summary>
            [Description("Binary (Logistic)")]
            [GPEnumValue("BINARY")]
            _BINARY,

            /// <summary>
            /// <para>Count (Poisson)</para>
            /// <para>Count (Poisson)—The Dependent Variable value is discrete and represents events, such as crime counts, disease incidents, or traffic accidents. The Poisson regression model will be used.</para>
            /// <para>计数 （Poisson） - 因变量值是离散的，表示事件，例如犯罪计数、疾病事件或交通事故。将使用泊松回归模型。</para>
            /// </summary>
            [Description("Count (Poisson)")]
            [GPEnumValue("COUNT")]
            _COUNT,

        }

        /// <summary>
        /// <para>Explanatory Variable(s)</para>
        /// <para>A list of fields representing independent explanatory variables in the regression model.</para>
        /// <para>表示回归模型中独立解释变量的字段列表。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Explanatory Variable(s)")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public List<object> _explanatory_variables { get; set; }


        /// <summary>
        /// <para>Output Features</para>
        /// <para>The new feature class containing the dependent variable estimates and residuals.</para>
        /// <para>包含因变量估计值和残差的新要素类。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _output_features { get; set; }


        /// <summary>
        /// <para>Neighborhood Type</para>
        /// <para><xdoc>
        ///   <para>Specifies whether the neighborhood used is constructed as a fixed distance or allowed to vary in spatial extent depending on the density of the features.</para>
        ///   <bulletList>
        ///     <bullet_item>Number of neighbors— The neighborhood size is a function of a specified number of neighbors included in calculations for each feature. Where features are dense, the spatial extent of the neighborhood is smaller; where features are sparse, the spatial extent of the neighborhood is larger.</bullet_item><para/>
        ///     <bullet_item>Distance band—The neighborhood size is a constant or fixed distance for each feature.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定所使用的邻域是构造为固定距离，还是允许根据要素的密度在空间范围内变化。</para>
        ///   <bulletList>
        ///     <bullet_item>邻域数 - 邻域大小是每个要素的计算中包含的指定数目邻域的函数。要素密集的地方，邻域的空间范围较小;要素稀疏的地方，邻域的空间范围较大。</bullet_item><para/>
        ///     <bullet_item>距离带 - 邻域大小是每个要素的常数或固定距离。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Neighborhood Type")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public _neighborhood_type_value? _neighborhood_type { get; set; }

        public enum _neighborhood_type_value
        {
            /// <summary>
            /// <para>Number of neighbors</para>
            /// <para>Number of neighbors— The neighborhood size is a function of a specified number of neighbors included in calculations for each feature. Where features are dense, the spatial extent of the neighborhood is smaller; where features are sparse, the spatial extent of the neighborhood is larger.</para>
            /// <para>邻域数 - 邻域大小是每个要素的计算中包含的指定数目邻域的函数。要素密集的地方，邻域的空间范围较小;要素稀疏的地方，邻域的空间范围较大。</para>
            /// </summary>
            [Description("Number of neighbors")]
            [GPEnumValue("NUMBER_OF_NEIGHBORS")]
            _NUMBER_OF_NEIGHBORS,

            /// <summary>
            /// <para>Distance band</para>
            /// <para>Distance band—The neighborhood size is a constant or fixed distance for each feature.</para>
            /// <para>距离带 - 邻域大小是每个要素的常数或固定距离。</para>
            /// </summary>
            [Description("Distance band")]
            [GPEnumValue("DISTANCE_BAND")]
            _DISTANCE_BAND,

        }

        /// <summary>
        /// <para>Neighborhood Selection Method</para>
        /// <para><xdoc>
        ///   <para>Specifies how the neighborhood size will be determined. The neighborhood selected with the Golden search and Manual intervals options is based on minimizing the AICc value.</para>
        ///   <bulletList>
        ///     <bullet_item>Golden search—The tool will identify an optimal distance or number of neighbors based on the characteristics of the data using the golden section search method.</bullet_item><para/>
        ///     <bullet_item>Manual intervals— The neighborhoods tested will be defined by the values specified in the Minimum Number of Neighbors and Number of Neighbors Increment parameters when Number of neighbors is chosen for the Neighborhood Type parameter, or the Minimum Search Distance and Search Distance Increment parameters when Distance band is chosen for the Neighborhood Type parameter, as well as the Number of Increments parameter.</bullet_item><para/>
        ///     <bullet_item>User defined— The neighborhood size will be specified by either the Number of Neighbors or Distance Band parameter.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定如何确定邻域大小。使用黄金搜索和手动间隔选项选择的邻域基于最小化 AICc 值。</para>
        ///   <bulletList>
        ///     <bullet_item>黄金搜索 - 该工具将使用黄金分割搜索方法根据数据的特征识别最佳距离或邻居数量。</bullet_item><para/>
        ///     <bullet_item>手动间隔 - 当为邻域类型参数选择邻域数时，测试的邻域将由最小邻域数和邻域数增量参数中指定的值定义，或者当邻域类型参数选择距离带时，由最小搜索距离和搜索距离增量参数以及增量数参数中指定的值定义。</bullet_item><para/>
        ///     <bullet_item>用户定义 — 邻域大小将由邻居数或距离波段参数指定。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Neighborhood Selection Method")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public _neighborhood_selection_method_value? _neighborhood_selection_method { get; set; }

        public enum _neighborhood_selection_method_value
        {
            /// <summary>
            /// <para>Golden search</para>
            /// <para>Golden search—The tool will identify an optimal distance or number of neighbors based on the characteristics of the data using the golden section search method.</para>
            /// <para>黄金搜索 - 该工具将使用黄金分割搜索方法根据数据的特征识别最佳距离或邻居数量。</para>
            /// </summary>
            [Description("Golden search")]
            [GPEnumValue("GOLDEN_SEARCH")]
            _GOLDEN_SEARCH,

            /// <summary>
            /// <para>Manual intervals</para>
            /// <para>Manual intervals— The neighborhoods tested will be defined by the values specified in the Minimum Number of Neighbors and Number of Neighbors Increment parameters when Number of neighbors is chosen for the Neighborhood Type parameter, or the Minimum Search Distance and Search Distance Increment parameters when Distance band is chosen for the Neighborhood Type parameter, as well as the Number of Increments parameter.</para>
            /// <para>手动间隔 - 当为邻域类型参数选择邻域数时，测试的邻域将由最小邻域数和邻域数增量参数中指定的值定义，或者当邻域类型参数选择距离带时，由最小搜索距离和搜索距离增量参数以及增量数参数中指定的值定义。</para>
            /// </summary>
            [Description("Manual intervals")]
            [GPEnumValue("MANUAL_INTERVALS")]
            _MANUAL_INTERVALS,

            /// <summary>
            /// <para>User defined</para>
            /// <para>User defined— The neighborhood size will be specified by either the Number of Neighbors or Distance Band parameter.</para>
            /// <para>用户定义 — 邻域大小将由邻居数或距离波段参数指定。</para>
            /// </summary>
            [Description("User defined")]
            [GPEnumValue("USER_DEFINED")]
            _USER_DEFINED,

        }

        /// <summary>
        /// <para>Minimum Number of Neighbors</para>
        /// <para>The minimum number of neighbors each feature will include in its calculations. It is recommended that you use at least 30 neighbors.</para>
        /// <para>每个要素在其计算中将包含的最小邻域数。建议您至少使用 30 个邻居。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Minimum Number of Neighbors")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public long? _minimum_number_of_neighbors { get; set; } = null;


        /// <summary>
        /// <para>Maximum Number of Neighbors</para>
        /// <para>The maximum number of neighbors (up to 1000) each feature will include in its calculations.</para>
        /// <para>每个要素的最大邻居数（最多 1000 个）将包含在其计算中。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Maximum Number of Neighbors")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public long? _maximum_number_of_neighbors { get; set; } = null;


        /// <summary>
        /// <para>Minimum Search Distance</para>
        /// <para>The minimum neighborhood search distance. It is recommended that you use a distance at which each feature has at least 30 neighbors.</para>
        /// <para>最小邻域搜索距离。建议使用每个要素至少有 30 个相邻要素的距离。</para>
        /// <para>单位： Feet | Meters | Kilometers | Miles </para>
        /// </summary>
        [DisplayName("Minimum Search Distance")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string? _minimum_search_distance { get; set; } = null;


        /// <summary>
        /// <para>Maximum Search Distance</para>
        /// <para>The maximum neighborhood search distance. If a distance results in features with more than 1000 neighbors, the tool will use the first 1000 in calculations for the target feature.</para>
        /// <para>最大邻域搜索距离。如果距离导致要素具有超过 1000 个相邻要素，则该工具将在目标要素的计算中使用前 1000 个。</para>
        /// <para>单位： Feet | Meters | Kilometers | Miles </para>
        /// </summary>
        [DisplayName("Maximum Search Distance")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string? _maximum_search_distance { get; set; } = null;


        /// <summary>
        /// <para>Number of Neighbors Increment</para>
        /// <para>The number of neighbors by which manual intervals will increase for each neighborhood test.</para>
        /// <para>每个邻域测试的手动间隔将增加的邻域数。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Number of Neighbors Increment")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public long? _number_of_neighbors_increment { get; set; } = null;


        /// <summary>
        /// <para>Search Distance Increment</para>
        /// <para>The distance by which manual intervals will increase for each neighborhood test.</para>
        /// <para>每个邻域测试的手动间隔将增加的距离。</para>
        /// <para>单位： Feet | Meters | Kilometers | Miles </para>
        /// </summary>
        [DisplayName("Search Distance Increment")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string? _search_distance_increment { get; set; } = null;


        /// <summary>
        /// <para>Number of Increments</para>
        /// <para>The number of neighborhood sizes to test starting with the Minimum Number of Neighbors or Minimum Search Distance parameter.</para>
        /// <para>要测试的邻域大小数，从最小邻居数或最小搜索距离参数开始。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Number of Increments")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public long? _number_of_increments { get; set; } = null;


        /// <summary>
        /// <para>Number of Neighbors</para>
        /// <para>The closest number of neighbors (up to 1000) to consider for each feature. The number must be an integer between 2 and 1000.</para>
        /// <para>每个要素要考虑的最接近的邻居数（最多 1000 个）。该数字必须是介于 2 和 1000 之间的整数。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Number of Neighbors")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public long? _number_of_neighbors { get; set; } = null;


        /// <summary>
        /// <para>Distance Band</para>
        /// <para>The spatial extent of the neighborhood.</para>
        /// <para>邻域的空间范围。</para>
        /// <para>单位： Feet | Meters | Kilometers | Miles </para>
        /// </summary>
        [DisplayName("Distance Band")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string? _distance_band { get; set; } = null;


        /// <summary>
        /// <para>Prediction Locations</para>
        /// <para>A feature class containing features representing locations where estimates will be computed. Each feature in this dataset should contain values for all the explanatory variables specified. The dependent variable for these features will be estimated using the model calibrated for the input feature class data. To be predicted, these feature locations should be within the same study area as the Input Features or be close (within the extent plus 15 percent).</para>
        /// <para>包含表示将计算估计值的位置的要素的要素类。此数据集中的每个要素都应包含所有指定解释变量的值。这些要素的因变量将使用为输入要素类数据校准的模型进行估计。要进行预测，这些要素位置应与输入要素位于同一研究区域内或接近（在范围加 15% 范围内）。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Prediction Locations")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _prediction_locations { get; set; } = null;


        /// <summary>
        /// <para>Explanatory Variables to Match</para>
        /// <para>The explanatory variables from the Prediction Locations parameter that match corresponding explanatory variables from the Input Feature Class parameter.</para>
        /// <para>预测位置参数中的解释变量，与输入要素类参数中的相应解释变量匹配。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Explanatory Variables to Match")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _explanatory_variables_to_match { get; set; } = null;


        /// <summary>
        /// <para>Output Predicted Features</para>
        /// <para>The output feature class that will receive dependent variable estimates for each Prediction Location.</para>
        /// <para>将接收每个预测位置的因变量估计值的输出要素类。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Predicted Features")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _output_predicted_features { get; set; } = null;


        /// <summary>
        /// <para>Robust Prediction</para>
        /// <para><xdoc>
        ///   <para>Specifies the features that will be used in prediction calculations.</para>
        ///   <bulletList>
        ///     <bullet_item>Checked—Features with values more than three standard deviations from the mean (value outliers) and features with weights of 0 (spatial outliers) will be excluded from prediction calculations but will receive predictions in the output feature class. This is the default.</bullet_item><para/>
        ///     <bullet_item>Unchecked—All features will be used in prediction calculations.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定将在预测计算中使用的要素。</para>
        ///   <bulletList>
        ///     <bullet_item>选中 - 值与均值相差超过 3 个标准差的要素（值异常值）和权重为 0（空间异常值）的要素将从预测计算中排除，但将在输出要素类中接收预测。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>未选中—所有要素都将用于预测计算。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Robust Prediction")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _robust_prediction_value _robust_prediction { get; set; } = _robust_prediction_value._true;

        public enum _robust_prediction_value
        {
            /// <summary>
            /// <para>ROBUST</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("ROBUST")]
            [GPEnumValue("true")]
            _true,

            /// <summary>
            /// <para>NON_ROBUST</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("NON_ROBUST")]
            [GPEnumValue("false")]
            _false,

        }

        /// <summary>
        /// <para>Local Weighting Scheme</para>
        /// <para><xdoc>
        ///   <para>Specifies the kernel type that will be used to provide the spatial weighting in the model. The kernel defines how each feature is related to other features within its neighborhood.</para>
        ///   <bulletList>
        ///     <bullet_item>Bisquare—A weight of 0 will be assigned to any feature outside the neighborhood specified. This is the default.</bullet_item><para/>
        ///     <bullet_item>Gaussian—All features will receive weights, but weights become exponentially smaller the farther away they are from the target feature.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定将用于在模型中提供空间权重的核类型。内核定义每个特征如何与其邻域中的其他特征相关联。</para>
        ///   <bulletList>
        ///     <bullet_item>双正方形—权重 0 将分配给指定邻域之外的任何要素。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>高斯 - 所有要素都将接收权重，但权重与目标要素的距离越远，权重就会呈指数级变小。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Local Weighting Scheme")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _local_weighting_scheme_value _local_weighting_scheme { get; set; } = _local_weighting_scheme_value._BISQUARE;

        public enum _local_weighting_scheme_value
        {
            /// <summary>
            /// <para>Gaussian</para>
            /// <para>Gaussian—All features will receive weights, but weights become exponentially smaller the farther away they are from the target feature.</para>
            /// <para>高斯 - 所有要素都将接收权重，但权重与目标要素的距离越远，权重就会呈指数级变小。</para>
            /// </summary>
            [Description("Gaussian")]
            [GPEnumValue("GAUSSIAN")]
            _GAUSSIAN,

            /// <summary>
            /// <para>Bisquare</para>
            /// <para>Bisquare—A weight of 0 will be assigned to any feature outside the neighborhood specified. This is the default.</para>
            /// <para>双正方形—权重 0 将分配给指定邻域之外的任何要素。这是默认设置。</para>
            /// </summary>
            [Description("Bisquare")]
            [GPEnumValue("BISQUARE")]
            _BISQUARE,

        }

        /// <summary>
        /// <para>Coefficient Raster Workspace</para>
        /// <para>The workspace where the coefficient rasters will be created. When this workspace is provided, rasters are created for the intercept and every explanatory variable.</para>
        /// <para>将在其中创建系数栅格的工作空间。提供此工作空间后，将为截距和每个解释变量创建栅格。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Coefficient Raster Workspace")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _coefficient_raster_workspace { get; set; } = null;


        /// <summary>
        /// <para>Coefficient Raster Layers</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Coefficient Raster Layers")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public List<object> _coefficient_raster_layers { get; set; }


        public GWR SetEnv(object cellSize = null, object geographicTransformations = null, object outputCoordinateSystem = null, object scratchWorkspace = null, object snapRaster = null, object workspace = null)
        {
            base.SetEnv(cellSize: cellSize, geographicTransformations: geographicTransformations, outputCoordinateSystem: outputCoordinateSystem, scratchWorkspace: scratchWorkspace, snapRaster: snapRaster, workspace: workspace);
            return this;
        }

    }

}